﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Wicresoft.EKA.CommonExtensions;

namespace Wicresoft.EKA.NRemedy
{
    public class ARServerAndLastUsedTime : ICleanUpper
    {
        
        private DateTime _lastUsedTime;

        public DateTime LastUsedTime
        {
            get
            {
                return this._lastUsedTime;
            }
            set
            {
                this._lastUsedTime = value;
            }
        }

        private IARServer _arServer;

        public IARServer ARServer {

            get
            {
                return _arServer;
            }
            set
            {
                this._arServer = value;
            }
        
        
        }


        public void Dispose()
        {
            if (_arServer != null)
            {
                _arServer.Dispose();
                _arServer.ContextContainer.IsARServerReleased = true;
            }
            _arServer = null;
        }
    }
}
